-
Notifications
You must be signed in to change notification settings - Fork 13.3k
change definitely unproductive cycles to error #137314
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This comment has been minimized.
This comment has been minimized.
908a6ad
to
25621e4
Compare
☔ The latest upstream changes (presumably #137466) made this pull request unmergeable. Please resolve the merge conflicts. |
dc88ce2
to
da01707
Compare
Some changes occurred to the core trait solver cc @rust-lang/initiative-trait-system-refactor |
c6ab624
to
fa26c12
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- better document
Inductive
goal sources, explain WHY that's correct and the that it's safer to beUnknown
- this impacts coherence, write test
b81c189
to
fc8a474
Compare
I've changed the approach to keep known inductive cycles as ambig as coherence and added a test which will be affected if we change this in the future. As coherence is already stable I would like to give this some time to make sure we're confident in the approach and to allow us to iterate further here without needing to FCP each change while it's still in flux. I would like to do one 'complete' FCP for cycle handling before stabilizing |
233fd9a
to
18809a2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ty for the comments
@bors r+ |
builds on top of #136824 by adding a third variant to
PathKind
for paths which may change to be coinductive in the future but must not be so right now. Most notably, impl where-clauses of not yet coinductive traits.With this, we can change cycles which are definitely unproductive to a proper error. This fixes rust-lang/trait-system-refactor-initiative#114. This does not affect stable as we keep these cycles as ambiguous during coherence.
r? @compiler-errors @nikomatsakis